<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport"
          content="width=device-width,initial-scale=1.0,maximum-scale=1.0,minimum-scale=1.0,user-scalable=no">
    <title>水果商铺</title>
    <link rel="stylesheet" href="/static/css/fruit_list.css">

</head>
<body>
<div class="header-nav">
    <div class="user-img">
        <img src="https://ss2.bdstatic.com/70cFvnSh_Q1YnxGkpoWK1HF6hhy/it/u=2271338977,1611087163&fm=26&gp=0.jpg"/>
    </div>
    <div class="right-box">
        <button>注册</button>
        <a href="/user/login">登录</a>
    </div>
</div>
<div class="middle">
    <div class="int">
        <p>价格区间:</p>
        <span>
            <form method="get">
                <input name="price1" value="{% if price1 %}{{ price1 }}{% else %}0{% endif %}">
                ---
                <input name="price2" value="{% if price2 %}{{ price2 }}{% else %}1000{% endif %}">
                <button>确定</button>
            </form>
        </span>
    </div>
</div>
<div class="body">
    <div class="left-body">
        {% for fruit in fruits %}
            <div class="fruit">
                <div class="name">
                    <p>{{ fruit.name }}</p>
                    <p class="store">{{ fruit.store_name }}</p>
                </div>
                <div class="fruit-img">
                    <img src="{% if fruit.img %}/media/{{ fruit.img }}{% else %}https://seopic.699pic.com/photo/50014/6326.jpg_wh1200.jpg{% endif %}">
                    <div class="con">
                        <text>{% if fruit.summary %}{{ fruit.summary }}{% else %}这是水果{% endif %}</text>
                    </div>
                </div>
                <div class="introduce">
                    <p class="price">￥{{ fruit.price }}&nbsp;元/斤</p>
                    <p class="source">产地：{{ fruit.source }}</p>
                    <p class="cate">分类：{{ fruit.category }}</p>
                </div>
            </div>
        {% endfor %}
    </div>
    <div class="right-body">
        <div class="ranking">
            <p class="rank">总排行</p>
            <div class="rank-con">
                <ul>
                    {% for store in stores %}
                        <li>{{ store.name }}---{{ store.create_time }}</li>
                    {% endfor %}
                </ul>
            </div>
        </div>
        <div class="recommend">
            <p class="rank">今日推荐</p>
            <div class="rank-con"></div>
        </div>
    </div>
</div>
<div class="foo">
    <p>Copyright&nbsp;&copy;&nbsp;&nbsp;LZ站长系统</p>
</div>
</body>
</html>